package com.gjy.spring.s7;

import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import org.springframework.beans.factory.DisposableBean;

import javax.annotation.PreDestroy;

/**
 * @author 宫静雨
 * @version 1.0
 * @since 2023-12-20 10:30:22
 */
public class Bean2 implements DisposableBean {
    private static final Logger log = LoggerFactory.getLogger(Bean2.class);

    @PreDestroy
    public void destroy1() {
        log.info("destroy1");
    }

    @Override
    public void destroy() throws Exception {
        log.info("destroy2");
    }

    public void destroy3() {
        log.info("destroy3");
    }
}
